-+-    DB Dumper for PROGRESS v1.30    *    Copyright (C) JP 2o12   -+-


Description
===========
DB Dumper can extract defined tables from various DBs to external file.
So you can theoretically use it with any database.  ( For correct work
you must have right  ODBC driver of course )  The main purpose of this
program was migrate some data between PROGRESS and other databases.

How to use it
=============
First you must have right ODBC driver and valid connect string to ODBC.
Then open notepad and create new script file. Check examples.

- OUTPUT DIRECTORY: where are extracted data placed

- EXTRACTION TYPE: you can use TABLE/FIELD for whole table or only for
  selected fields

  Setting example for FIELD mode:
    ### Defined Tables/Fields
    TABLE; FIELD_NAME
    e.g.
    ORDERS; DECRIPTION
    ORDERS; ORDER_DATE

  Setting example for TABLE mode:
    ### Defined Tables/Fields
    TABLE
    e.g.
    ORDERS
    INVOICES

- RUN PROGRAM AFTER EXPORT:  you can  define  what program  should run
  after export

From menu select "Open Script (F3)" and open your script file.  In log
window appear message about connect string  and numbers of tables that
are loaded.  If you want see  list of all tables  in database then you
can choose from menu "List Tables (F6)".

First button [Check]  will try only connect to DB and valid all tables
that you defined as accessible. You get detailed report about process.

Second button  [Export]  will dump tables that you defined into files.

- AUTO MODE
  You can also use it in automatic mode for export.  Just put to command
  line parameter  -a C:\TestDB\Script_3.txt  and for export will be used
  Script_3.txt.

- Export BLOB data mode
  In script use BLOB switch = "Y", which mean export BLOB field as file.
  By setting this option "Mode Type of definition (TABLE/FIELD)" is ignored.

Setting example:
  ### WHERE condition
  NOT PICTURE_DATA IS NULL AND PICTURE_FILENAME  <> ''
  ### Defined Tables/Fields
  TABLE; FIELD_BLOB; FIELD_FILENAME; TRY_CONVERT (0/1)
  e.g.
  PICTURES; PICTURE_DATA; PICTURE_FILENAME; 0

Description:
  Export from TABLE blob field FIELD_BLOB and give to file name by contens of field
  FIELD_FILENAME. In FIELD_FILENAME can be integer (ID) or some other string and
  must be uniqe for each file, otherwise files can be owerwriten.
  Export only data that fit WHERE condition: fields that contain some data and
  have no empty file name.
  Some data are not in binary format so export will failed. Data must be before
  converted by setting TRY_CONVERT to 1. (Values can be only 0/1) First time try
  set to 0, if it's not working (files are with zero size) try set to 1.

List of recognized types in database:
  Empty = 0
  SmallInt = 2
  Integer = 3
  Single = 4
  Double = 5
  Currency = 6
  Date = 7
  BSTR = 8
  IDispatch = 9
  Error = 10
  Boolean = 11
  Variant = 12
  IUnknown = 13
  Decimal = 14
  TinyInt = 16
  UnsignedTinyInt = 17
  UnsignedSmallInt = 18
  UnsignedInt = 19
  BigInt = 20
  UnsignedBigInt = 21
  FileTime = 64
  GUID = 72
  Binary = 128
  Char = 129
  WChar = 130
  Numeric = 131
  UserDefined = 132
  DBDate = 133
  DBTime = 134
  DBTimeStamp = 135
  Chapter = 136
  DBFileTime = 137
  PropVariant = 138
  VarNumeric = 139
  VarChar = 200
  LongVarChar = 201
  VarWChar = 202
  LongVarWChar = 203
  VarBinary = 204
  LongVarBinary = 205

You can download also some examples from main site:

1) Extract data from Delphi Interbase database to text file and load
   it to PROGRESS database
2) Extract data from PROGRESS database to text file with external
   program (DB Dumper) for other processing.
3) Extract data from Microsoft Access MDB Database to text file with
   external program (DB Dumper) for other processing.
4) Extract BLOB data from SQL server to files with unique names taken from some 
   field with external program (DB Dumper) for other processing.
   
Shortcuts:
- Open Export Script (F3)
- Save Report (F2)
- Exit (F12)
- List Tables (F6)

Known limitations, Bugs
=======================
Not all data types are supported. You can get sometime warning message
about unsupported type. Also some types can be wrong converted.  Check
the output carefully !

Use this application entirely at your own risk.  The author assumes no
liability for any loss associated with  the use  of  this application.
If you do not agree with the terms,  do not use this application.

Contact
=======
Visit http://progress-tools.x10.mx for more information or updates.  If you have
some ideas,  comments,  improvements or you find some bug you can mail to me at
darker@azet.sk

System requirements
===================
VB6 runtime  MSVBVM60.DLL, COMDLG32.OCX  and COMCTL32.OCX, but i think
you already have it in system or you can download it from web.

History
=======
1.0 - [27.06.2006]
Initial version.

1.1 - [27.06.2007]
Fix: Code rewritten
Add: User defined delimiter
Add: Run program after export
Add: TABLE/FIELDS Option for export
Add: Setting Output dir in script
Add: Commandline for Automatic batch

1.2 - [01.07.2010]
Add: Export blob data from database

1.30 - [26.06.2012]
Add: WHERE condition parameter
